package com.xayy.health.mgt.model;

import cn.kawins.mybatis.base.BaseModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;

import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;

/**
 * 模型训练记录表
 * @author zhangxa
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "HEALTH.tb_model_train_record")
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
public class ModelTrainRecord extends BaseModel<String> {

    @Id
    @ApiModelProperty(value = "id")
    @Column(name = "id")
    private String id;

    @ApiModelProperty(value = "卫星代号")
    @Column(name = "satellite_code")
    private String satelliteCode;

    @ApiModelProperty(value = "参数")
    @Column(name = "param_code")
    private String paramCode;

    @ApiModelProperty(value = "参数名称")
    @Column(name = "param_code_name")
    private String paramCodeName;

    @ApiModelProperty(value = "开始时间")
    @Column(name = "start_time")
    private Date startTime;

    @ApiModelProperty(value = "结束时间")
    @Column(name = "end_time")
    private Date endTime;

    @ApiModelProperty(value = "异常开始时间")
    @Column(name = "error_start")
    private String errorStart;

    @ApiModelProperty(value = "异常结束时间")
    @Column(name = "error_end")
    private String errorEnd;

    @ApiModelProperty(value = "模型名称")
    @Column(name = "model_name")
    private String modelName;

    @ApiModelProperty(value = "模型类型")
    @Column(name = "model_type")
    private Integer modelType;

    @ApiModelProperty(value = "算法名称")
    @Column(name = "algorithm_name")
    private String algorithmName;

    @ApiModelProperty(value = "门限值")
    @Column(name = "threshold")
    private String threshold;

    @ApiModelProperty(value = "准确度")
    @Column(name = "accuracy")
    private String accuracy;

    @ApiModelProperty(value = "状态")
    @Column(name = "status")
    private Integer status;

    @Column(name = "create_time")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    @Column(name = "update_time")
    @ApiModelProperty(value = "更新时间")
    private Date updateTime;


    @ApiModelProperty(value = "偏差值")
    @Column(name="offset")
    private String offset;

    @ApiModelProperty(value = "旧模型名称")
    @Column(name="old_model_name")
    private String oldModelName;
    @Override
    public String idValue() {
        return id;
    }
}
